package com.dnjn.happiness.score.enums;


import lombok.AllArgsConstructor;
import lombok.Getter;

@AllArgsConstructor
@Getter
public enum AppriseEnum {

    A(1, -40.0),

    B(2, -30.0),

    C(3, -20.0),

    D(4, -10.0),

    E(5, 10.0),

    F(6, 20.0),

    G(7, 30.0),

    H(8, 40.0),

    I(9, 50.0),

    J(10, 60.0);


    @Getter
    private Integer a;
    @Getter
    private Double b;


    public static Double getB(Integer appriseLikeCount) {
        AppriseEnum[] values = AppriseEnum.values();
        for (AppriseEnum appriseEnum : values) {
            if (appriseLikeCount.equals(appriseEnum.a)) {
                return appriseEnum.b;
            }
        }
        return 0.0;

    }

}
